package ModelLayer;

/**
 * Write a description of class Person here.
 * 
 * @author (your name) 
 * @version (a version number or a date)
 */
public class Copy
{
    // instance variables - replace the example below with your own
    private int serieno;
    private String acdate;
    private int acprice;
    private boolean loaned;

    public Copy(int serieno, String acdate, int acprice)
    {    
        this.serieno = serieno;
        this.acdate = acdate;
        this.acprice = acprice;
        loaned = false;
    }

    //get methods    
    public int getSerieno()
    {
        return serieno;
    }

    public String getAcdate()
    {
        return acdate;
    }

    public int getAcprice()
    {
        return acprice;
    }

    public boolean getLoaned()
    {
        return loaned;
    }

    //set methods
    public void setSerieno(int serieno)
    {
        this.serieno = serieno;
    }

    public void setAcdate(String acdate)
    {
        this.acdate = acdate;
    }

    public void setAcprice(int acprice)
    {
        this.acprice = acprice;
    }

    public void setLoaned(boolean loaned)
    {
        this.loaned = loaned;
    }

    public void printDetail()
    {
        if(getSerieno() != 0)
        {
            System.out.println();
            System.out.println("# DVD copy: "+ getSerieno());
            System.out.println("  #----------------------------------");
            System.out.println("  # ID        :"+ serieno);
            System.out.println("  # ac. date  :"+ acdate);
            System.out.println("  # ac. price :"+ acprice);        
        }
        else
        {
            System.out.println("  # No copy is created! ");
        }
    }
    
    
}
